package com.yonyou.pmclouds.inspectitem.entity;

import com.yonyou.pmclouds.basecom.entity.SuperVO;
import com.yonyou.pmclouds.copyperson.entity.CopyPersonVO;
import com.yonyou.pmclouds.measuredata.entity.MeasureDataVO;
import com.yonyou.pmclouds.picture.entity.PictureVO;
import lombok.Getter;
import lombok.Setter;

import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Transient;
import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * 现场检查表体--检查项vo
 * @author fangpengc
 *
 */
@Table(name="pm_inspectitem")
@Setter
@Getter
public class InspectItemVO extends SuperVO{

    private static final long serialVersionUID = -7676434957969325934L;
    public static String PK_PROCESS = "pk_process";
    public static String PK_PROBLEMREASON = "pk_problemreason";
    public static String PK_ITEM = "pk_item";
    public static String[] REF_FILEDS = {PK_PROCESS,PK_PROBLEMREASON,PK_ITEM};
    public static String PK_RECTIFICATIONER = "pk_rectificationer";
    public static String RECTIFICATIONER_NAME = "rectificationer_name";
    public static String BILLSTATUS = "billstatus";
    public static String MEMO = "memo";
    public static String PHOTOSTATUS = "photostatus";
    public static String MEASURESTATUS = "measurestatus";
    @Id
    private String pk_inspectitem;
    /**
     * 表头主键
     */
    private String pk_bill;
    /**
     * 检查项
     */
    private String pk_item;   //检查标准的检查项主键
    //这个表示通过 不通过
    private byte billstatus;
    private String memo;
    private String pk_project;
    /**
     * 是否推送
     */
    private boolean ispush;             //是否推送
    private String pk_rectificationer;  //整改人
    /**
     * 问题原因
     */
    private String pk_problemreason;  //问题原因
    private String pk_process;     //工序

    /**
     * 完成期限
     */
    private Date enddate;
    @Transient
    private String position;  //位置信息
    @Transient
    private BigDecimal longitude;   // 经度
    @Transient
    private BigDecimal latitude;  // 纬度
    /**
     * 是否需要照片
     */
    private byte photostatus;
    /**
     * 是否需要测试数据
     */
    private byte measurestatus;
    // 检查项排序用
    private Integer sequence;
    @Transient
    private String problemreason_name;
    @Transient
    private String process_name;

    @Transient
    private String rectificationer_name;


    /**
     * 检查项名称
     */
    @Transient
    private String item_name;
    /**
     * 检查项描述
     */
    @Transient
    private String item_content;
    /**
     * 测量数据
     */
    @Transient
    private Double[] datas;
    // 数据对象，供前台判别位置
    @Transient
    private MeasureDataVO[] measureData;
    /**
     * 照片
     */
    @Transient
    private String[] pictures;
    // 照片真实地址(用于存储HTML形式)
    @Transient
    private String picture_address;
    @Transient
    private String pk_tenant;
    // 施工记录主键（打印预览需要）
    @Transient
    private String pk_constructionlog;
    @Transient
    private String pk_siteinspection;
    @Transient
    private String pkComprehensiveAcceptance;

    // 检查项数据（打印预览需要）
    @Transient
    private String itemDatas;
    // 检查项质量（合格，不合格，不适用）(打印预览需要）
    @Transient
    private String itemQuality;
    //是否编辑检查项
    @Transient
    private boolean modified;

    @Transient
    private List<CopyPersonVO> copyPersonVOS;

    @Transient
    private String creator;

    @Transient
    private String creatorName;

    // 问题描述
    @Transient
    private String problemContent;

    /**
     * 示例照片
     */
    @Transient
    private PictureVO[] examplePictures;

    /**
     * 整改区域
     */
    private String improvement_area;

}
